import { http } from '@idmy/core'

export function allProjects() {
  return http.post('/api/sys/Project/all', null, { appKey: 'sys' })
}

export function createOrUpdateApp(model) {
  if (model.id) {
    return http.post('/api/sys/App/update', model, { appKey: 'sys' })
  } else {
    return http.post('/api/sys/App/create', model, { appKey: 'sys' })
  }
}
